cmake_minimum_required(VERSION 3.4.1)

project(${TARGETS})

add_definitions("-Wall -g")

set(SRC_LIST
    sock/Socktool.cpp
    sock/Epolltool.cpp
    sock/Service.cpp
    sock/Event.cpp
    kisql/kisql.cpp
    syslog/Log.cpp

    presenter/userPresenter.cpp
    presenter/PlayerPresenter.cpp
    presenter/TaskPresenter.cpp
    presenter/MapPresenter.cpp
    presenter/BossPresenter.cpp
    presenter/EnemyPresenter.cpp
    presenter/NpcPresenter.cpp

    dao/UserDao.cpp
    dao/PlayerDao.cpp
    dao/MapDao.cpp
    dao/BossDao.cpp
    dao/EnemyDao.cpp
    dao/NpcDao.cpp
    dao/TaskDao.cpp

    ../include/tool/Util.h
    ../include/data/PlayerBean.h
    ../include/data/MapExitBean.h
    ../include/data/BossBean.h
    ../include/data/MidEnemyBean.h
    ../include/data/EnemyBean.h
    ../include/data/NpcBean.h

    ../include/dao/PlayerDao.h
    ../include/dao/MapDao.h
    ../include/dao/BossDao.h
    ../include/dao/EnemyDao.h
    ../include/dao/NpcDao.h

    ../include/presenter/MapPresenter.h
    ../include/presenter/BossPresenter.h
    ../include/presenter/EnemyPresenter.h
    ../include/presenter/NpcPresenter.h

)

LINK_DIRECTORIES(${PROJECT_SOURCE_DIR}/lib)
add_executable(${TARGETS} app.cpp ${SRC_LIST})

TARGET_LINK_LIBRARIES(${TARGETS} pthread jsoncpp mysqlclient)

